(module binary
  "\00\61\73\6d\01\00\00\00\01\92\80\80\80\00\04\60"
  "\00\00\60\01\7f\01\7f\60\01\7f\00\60\02\7f\7f\00"
  "\03\93\80\80\80\00\12\00\01\01\02\01\01\01\01\01"
  "\02\03\03\01\01\01\01\01\01\07\c6\82\80\80\00\11"
  "\0e\61\73\2d\62\6c\6f\63\6b\2d\66\69\72\73\74\00"
  "\01\0c\61\73\2d\62\6c\6f\63\6b\2d\6d\69\64\00\02"
  "\0d\61\73\2d\62\6c\6f\63\6b\2d\6c\61\73\74\00\03"
  "\14\61\73\2d\62\6c\6f\63\6b\2d\66\69\72\73\74\2d"
  "\76\61\6c\75\65\00\04\12\61\73\2d\62\6c\6f\63\6b"
  "\2d\6d\69\64\2d\76\61\6c\75\65\00\05\13\61\73\2d"
  "\62\6c\6f\63\6b\2d\6c\61\73\74\2d\76\61\6c\75\65"
  "\00\06\0d\61\73\2d\6c\6f\6f\70\2d\66\69\72\73\74"
  "\00\07\0b\61\73\2d\6c\6f\6f\70\2d\6d\69\64\00\08"
  "\0c\61\73\2d\6c\6f\6f\70\2d\6c\61\73\74\00\09\0a"
  "\61\73\2d\69\66\2d\74\68\65\6e\00\0a\0a\61\73\2d"
  "\69\66\2d\65\6c\73\65\00\0b\12\6e\65\73\74\65\64"
  "\2d\62\6c\6f\63\6b\2d\76\61\6c\75\65\00\0c\0f\6e"
  "\65\73\74\65\64\2d\62\72\2d\76\61\6c\75\65\00\0d"
  "\12\6e\65\73\74\65\64\2d\62\72\5f\69\66\2d\76\61"
  "\6c\75\65\00\0e\17\6e\65\73\74\65\64\2d\62\72\5f"
  "\69\66\2d\76\61\6c\75\65\2d\63\6f\6e\64\00\0f\15"
  "\6e\65\73\74\65\64\2d\62\72\5f\74\61\62\6c\65\2d"
  "\76\61\6c\75\65\00\10\1b\6e\65\73\74\65\64\2d\62"
  "\72\5f\74\61\62\6c\65\2d\76\61\6c\75\65\2d\69\6e"
  "\64\65\78\00\11\0a\b5\83\80\80\00\12\82\80\80\80"
  "\00\00\0b\8e\80\80\80\00\00\02\40\20\00\0d\00\41"
  "\02\0f\0b\41\03\0b\90\80\80\80\00\00\02\40\10\00"
  "\20\00\0d\00\41\02\0f\0b\41\03\0b\8d\80\80\80\00"
  "\00\02\40\10\00\10\00\20\00\0d\00\0b\0b\8f\80\80"
  "\80\00\00\02\7f\41\0a\20\00\0d\00\1a\41\0b\0f\0b"
  "\0b\91\80\80\80\00\00\02\7f\10\00\41\14\20\00\0d"
  "\00\1a\41\15\0f\0b\0b\8f\80\80\80\00\00\02\7f\10"
  "\00\10\00\41\0b\20\00\0d\00\0b\0b\91\80\80\80\00"
  "\00\02\40\03\40\20\00\0d\01\41\02\0f\0b\0b\41\03"
  "\0b\93\80\80\80\00\00\02\40\03\40\10\00\20\00\0d"
  "\01\41\02\0f\0b\0b\41\04\0b\8b\80\80\80\00\00\03"
  "\40\10\00\20\00\0d\01\0b\0b\91\80\80\80\00\00\02"
  "\40\20\00\04\40\20\01\0d\01\05\10\00\0b\0b\0b\91"
  "\80\80\80\00\00\02\40\20\00\04\40\10\00\05\20\01"
  "\0d\01\0b\0b\0b\9a\80\80\80\00\00\41\01\02\7f\41"
  "\02\1a\41\04\02\7f\41\08\20\00\0d\01\1a\41\10\0b"
  "\6a\0b\6a\0b\9b\80\80\80\00\00\41\01\02\7f\41\02"
  "\1a\02\7f\41\08\20\00\0d\01\1a\41\04\0b\0c\00\41"
  "\10\0b\6a\0b\9e\80\80\80\00\00\41\01\02\7f\41\02"
  "\1a\02\7f\41\08\20\00\0d\01\1a\41\04\0b\41\01\0d"
  "\00\1a\41\10\0b\6a\0b\9e\80\80\80\00\00\41\01\02"
  "\7f\41\02\1a\41\04\02\7f\41\08\20\00\0d\01\1a\41"
  "\01\0b\0d\00\1a\41\10\0b\6a\0b\9e\80\80\80\00\00"
  "\41\01\02\7f\41\02\1a\02\7f\41\08\20\00\0d\01\1a"
  "\41\04\0b\41\01\0e\00\00\41\10\0b\6a\0b\9e\80\80"
  "\80\00\00\41\01\02\7f\41\02\1a\41\04\02\7f\41\08"
  "\20\00\0d\01\1a\41\01\0b\0e\00\00\41\10\0b\6a\0b"
)
(assert_return (invoke "as-block-first" (i32.const 0)) (i32.const 2))
(assert_return (invoke "as-block-first" (i32.const 1)) (i32.const 3))
(assert_return (invoke "as-block-mid" (i32.const 0)) (i32.const 2))
(assert_return (invoke "as-block-mid" (i32.const 1)) (i32.const 3))
(assert_return (invoke "as-block-last" (i32.const 0)))
(assert_return (invoke "as-block-last" (i32.const 1)))
(assert_return (invoke "as-block-last-value" (i32.const 0)) (i32.const 11))
(assert_return (invoke "as-block-last-value" (i32.const 1)) (i32.const 11))
(assert_return (invoke "as-loop-first" (i32.const 0)) (i32.const 2))
(assert_return (invoke "as-loop-first" (i32.const 1)) (i32.const 3))
(assert_return (invoke "as-loop-mid" (i32.const 0)) (i32.const 2))
(assert_return (invoke "as-loop-mid" (i32.const 1)) (i32.const 4))
(assert_return (invoke "as-loop-last" (i32.const 0)))
(assert_return (invoke "as-loop-last" (i32.const 1)))
(assert_return (invoke "as-if-then" (i32.const 0) (i32.const 0)))
(assert_return (invoke "as-if-then" (i32.const 4) (i32.const 0)))
(assert_return (invoke "as-if-then" (i32.const 0) (i32.const 1)))
(assert_return (invoke "as-if-then" (i32.const 4) (i32.const 1)))
(assert_return (invoke "as-if-else" (i32.const 0) (i32.const 0)))
(assert_return (invoke "as-if-else" (i32.const 3) (i32.const 0)))
(assert_return (invoke "as-if-else" (i32.const 0) (i32.const 1)))
(assert_return (invoke "as-if-else" (i32.const 3) (i32.const 1)))
(assert_return (invoke "nested-block-value" (i32.const 0)) (i32.const 21))
(assert_return (invoke "nested-block-value" (i32.const 1)) (i32.const 9))
(assert_return (invoke "nested-br-value" (i32.const 0)) (i32.const 5))
(assert_return (invoke "nested-br-value" (i32.const 1)) (i32.const 9))
(assert_return (invoke "nested-br_if-value" (i32.const 0)) (i32.const 5))
(assert_return (invoke "nested-br_if-value" (i32.const 1)) (i32.const 9))
(assert_return (invoke "nested-br_if-value-cond" (i32.const 0)) (i32.const 5))
(assert_return (invoke "nested-br_if-value-cond" (i32.const 1)) (i32.const 9))
(assert_return (invoke "nested-br_table-value" (i32.const 0)) (i32.const 5))
(assert_return (invoke "nested-br_table-value" (i32.const 1)) (i32.const 9))
(assert_return
  (invoke "nested-br_table-value-index" (i32.const 0))
  (i32.const 5)
)
(assert_return
  (invoke "nested-br_table-value-index" (i32.const 1))
  (i32.const 9)
)
(assert_invalid
  (module binary
    "\00\61\73\6d\01\00\00\00\01\84\80\80\80\00\01\60"
    "\00\00\03\82\80\80\80\00\01\00\0a\90\80\80\80\00"
    "\01\8a\80\80\80\00\00\02\40\41\00\0d\00\68\0b\0b"
  )
  "type mismatch"
)
(assert_invalid
  (module binary
    "\00\61\73\6d\01\00\00\00\01\84\80\80\80\00\01\60"
    "\00\00\03\82\80\80\80\00\01\00\0a\90\80\80\80\00"
    "\01\8a\80\80\80\00\00\02\40\41\00\0d\00\7a\0b\0b"
  )
  "type mismatch"
)
(assert_invalid
  (module binary
    "\00\61\73\6d\01\00\00\00\01\84\80\80\80\00\01\60"
    "\00\00\03\82\80\80\80\00\01\00\0a\90\80\80\80\00"
    "\01\8a\80\80\80\00\00\02\40\41\00\0d\00\8c\0b\0b"
  )
  "type mismatch"
)
(assert_invalid
  (module binary
    "\00\61\73\6d\01\00\00\00\01\84\80\80\80\00\01\60"
    "\00\00\03\82\80\80\80\00\01\00\0a\90\80\80\80\00"
    "\01\8a\80\80\80\00\00\02\40\41\00\0d\00\9a\0b\0b"
  )
  "type mismatch"
)
(assert_invalid
  (module binary
    "\00\61\73\6d\01\00\00\00\01\84\80\80\80\00\01\60"
    "\00\00\03\82\80\80\80\00\01\00\0a\90\80\80\80\00"
    "\01\8a\80\80\80\00\00\02\40\41\01\0d\00\68\0b\0b"
  )
  "type mismatch"
)
(assert_invalid
  (module binary
    "\00\61\73\6d\01\00\00\00\01\84\80\80\80\00\01\60"
    "\00\00\03\82\80\80\80\00\01\00\0a\90\80\80\80\00"
    "\01\8a\80\80\80\00\00\02\40\42\01\0d\00\7a\0b\0b"
  )
  "type mismatch"
)
(assert_invalid
  (module binary
    "\00\61\73\6d\01\00\00\00\01\84\80\80\80\00\01\60"
    "\00\00\03\82\80\80\80\00\01\00\0a\93\80\80\80\00"
    "\01\8d\80\80\80\00\00\02\40\43\00\00\80\3f\0d\00"
    "\8c\0b\0b"
  )
  "type mismatch"
)
(assert_invalid
  (module binary
    "\00\61\73\6d\01\00\00\00\01\84\80\80\80\00\01\60"
    "\00\00\03\82\80\80\80\00\01\00\0a\90\80\80\80\00"
    "\01\8a\80\80\80\00\00\02\40\42\01\0d\00\9a\0b\0b"
  )
  "type mismatch"
)
(assert_invalid
  (module binary
    "\00\61\73\6d\01\00\00\00\01\85\80\80\80\00\01\60"
    "\00\01\7f\03\82\80\80\80\00\01\00\0a\91\80\80\80"
    "\00\01\8b\80\80\80\00\00\02\7f\41\00\0d\00\41\01"
    "\0b\0b"
  )
  "type mismatch"
)
(assert_invalid
  (module binary
    "\00\61\73\6d\01\00\00\00\01\85\80\80\80\00\01\60"
    "\00\01\7f\03\82\80\80\80\00\01\00\0a\91\80\80\80"
    "\00\01\8b\80\80\80\00\00\02\7f\41\01\0d\00\41\01"
    "\0b\0b"
  )
  "type mismatch"
)
(assert_invalid
  (module binary
    "\00\61\73\6d\01\00\00\00\01\84\80\80\80\00\01\60"
    "\00\00\03\82\80\80\80\00\01\00\0a\91\80\80\80\00"
    "\01\8b\80\80\80\00\00\02\40\41\00\41\00\0d\00\0b"
    "\0b"
  )
  "type mismatch"
)
(assert_invalid
  (module binary
    "\00\61\73\6d\01\00\00\00\01\84\80\80\80\00\01\60"
    "\00\00\03\82\80\80\80\00\01\00\0a\91\80\80\80\00"
    "\01\8b\80\80\80\00\00\02\40\41\00\41\01\0d\00\0b"
    "\0b"
  )
  "type mismatch"
)
(assert_invalid
  (module binary
    "\00\61\73\6d\01\00\00\00\01\85\80\80\80\00\01\60"
    "\00\01\7f\03\82\80\80\80\00\01\00\0a\92\80\80\80"
    "\00\01\8c\80\80\80\00\00\02\7f\01\41\00\0d\00\41"
    "\01\0b\0b"
  )
  "type mismatch"
)
(assert_invalid
  (module binary
    "\00\61\73\6d\01\00\00\00\01\85\80\80\80\00\01\60"
    "\00\01\7f\03\82\80\80\80\00\01\00\0a\92\80\80\80"
    "\00\01\8c\80\80\80\00\00\02\7f\01\41\01\0d\00\41"
    "\01\0b\0b"
  )
  "type mismatch"
)
(assert_invalid
  (module binary
    "\00\61\73\6d\01\00\00\00\01\85\80\80\80\00\01\60"
    "\00\01\7f\03\82\80\80\80\00\01\00\0a\94\80\80\80"
    "\00\01\8e\80\80\80\00\00\02\7f\42\01\41\00\0d\00"
    "\1a\41\01\0b\0b"
  )
  "type mismatch"
)
(assert_invalid
  (module binary
    "\00\61\73\6d\01\00\00\00\01\85\80\80\80\00\01\60"
    "\00\01\7f\03\82\80\80\80\00\01\00\0a\94\80\80\80"
    "\00\01\8e\80\80\80\00\00\02\7f\42\01\41\00\0d\00"
    "\1a\41\01\0b\0b"
  )
  "type mismatch"
)
(assert_invalid
  (module binary
    "\00\61\73\6d\01\00\00\00\01\84\80\80\80\00\01\60"
    "\00\00\03\82\80\80\80\00\01\00\0a\8e\80\80\80\00"
    "\01\88\80\80\80\00\00\02\40\01\0d\00\0b\0b"
  )
  "type mismatch"
)
(assert_invalid
  (module binary
    "\00\61\73\6d\01\00\00\00\01\84\80\80\80\00\01\60"
    "\00\00\03\82\80\80\80\00\01\00\0a\8f\80\80\80\00"
    "\01\89\80\80\80\00\00\02\40\42\00\0d\00\0b\0b"
  )
  "type mismatch"
)
(assert_invalid
  (module binary
    "\00\61\73\6d\01\00\00\00\01\85\80\80\80\00\01\60"
    "\00\01\7f\03\82\80\80\80\00\01\00\0a\92\80\80\80"
    "\00\01\8c\80\80\80\00\00\02\7f\41\00\01\0d\00\41"
    "\01\0b\0b"
  )
  "type mismatch"
)
(assert_invalid
  (module binary
    "\00\61\73\6d\01\00\00\00\01\85\80\80\80\00\01\60"
    "\00\01\7f\03\82\80\80\80\00\01\00\0a\94\80\80\80"
    "\00\01\8e\80\80\80\00\00\02\7f\41\00\02\40\41\01"
    "\0d\01\0b\0b\0b"
  )
  "type mismatch"
)
(assert_invalid
  (module binary
    "\00\61\73\6d\01\00\00\00\01\85\80\80\80\00\01\60"
    "\00\01\7f\03\82\80\80\80\00\01\00\0a\93\80\80\80"
    "\00\01\8d\80\80\80\00\00\02\7f\41\00\42\00\0d\00"
    "\41\01\0b\0b"
  )
  "type mismatch"
)
(assert_invalid
  (module binary
    "\00\61\73\6d\01\00\00\00\01\84\80\80\80\00\01\60"
    "\00\00\03\82\80\80\80\00\01\00\0a\8c\80\80\80\00"
    "\01\86\80\80\80\00\00\41\01\0d\01\0b"
  )
  "unknown label"
)
(assert_invalid
  (module binary
    "\00\61\73\6d\01\00\00\00\01\84\80\80\80\00\01\60"
    "\00\00\03\82\80\80\80\00\01\00\0a\92\80\80\80\00"
    "\01\8c\80\80\80\00\00\02\40\02\40\41\01\0d\05\0b"
    "\0b\0b"
  )
  "unknown label"
)
(assert_invalid
  (module binary
    "\00\61\73\6d\01\00\00\00\01\84\80\80\80\00\01\60"
    "\00\00\03\82\80\80\80\00\01\00\0a\90\80\80\80\00"
    "\01\8a\80\80\80\00\00\41\01\0d\81\80\80\80\01\0b"
  )
  "unknown label"
)
